import { Modal, Button, WhiteSpace, WingBlank, Toast } from 'antd-mobile';
import React from 'react'

const alert = Modal.alert;

const showAlert = () => {
    const alertInstance = alert('Delete', 'Are you sure???', [
        { text: 'Cancel', onPress: () => console.log('cancel'), style: 'default' },
        { text: 'OK', onPress: () => console.log('ok') },
    ]);
    setTimeout(() => {
        // 可以调用close方法以在外部close
        console.log('auto close');
        alertInstance.close();
    }, 500000);
};

class Alert extends React.Component {
    render() {
        return (
            <Button
            >
                返回
    </Button>
        )
    }
}

export default Alert